home *** CD-ROM | disk | FTP | other *** search
/ Collection of Tools & Utilities / Collection of Tools and Utilities.iso / dskut / fatman32.zip / FM32.TXT < prev   
Text File  |  1987-06-02  |  13KB  |  348 lines

  1.  
  2.  
  3.  
  4.  
  5.  
  6.  
  7.             
  8.  
  9.  
  10.  
  11.  
  12.                                    FM User's Guide
  13.  
  14.                               Version 3.2, June 2, 1987
  15.                          Copyright (c) 1987 by Thomas Stepka
  16.                                  7702 Lunceford Lane
  17.                                Falls Church, Va 22043
  18.                                  All rights reserved
  19.  
  20.  
  21.  
  22.  
  23.  
  24.  
  25.  
  26.           1. Intended Audience
  27.  
  28.           FM stands for FAT Manager, and FAT in turn stands for File
  29.           Allocation Table.  The FAT is a data structure put on every disk
  30.           by DOS during formatting, and it keeps track of which sectors of
  31.           the disk are allocated to each file in the directory.  If you
  32.           don't already know what a FAT or a cluster or a logical sector or
  33.           a cluster chain is, then you don't need this program.
  34.  
  35.  
  36.  
  37.  
  38.           2. Functions and Features
  39.  
  40.                FM was written to plug a functionality hole in existing
  41.           utility software.  I have often noticed DOS doing several retries
  42.           when trying to read a disk file, or even returning an I/O error;
  43.           but whenever I ran FORMAT or the Norton Utility DISKTEST, all
  44.           clusters would check out OK.  I wanted a way to arbitrarily mark
  45.           areas of the disk off limits to I/O, and to restore those areas
  46.           at any future time if I so wished.  FM is the result.
  47.  
  48.           Following are the basic functions and features of FM:
  49.  
  50.                a. List all clusters on the target disk by type (bad,
  51.                occupied or unused), with corresponding logical sector
  52.                numbers.  
  53.  
  54.                b. Display the status of a cluster or sector, including
  55.                which file or subdirectory (if any) occupies it.
  56.  
  57.                c. Enter numbers and display results in either decimal, hex,
  58.                or octal.
  59.  
  60.                d. Make unused clusters bad or reserved, so DOS will not use
  61.                them.
  62.  
  63.                e. Make bad or reserved clusters good, available for use
  64.                again.
  65.  
  66.                f. List all changes made to the FAT during a session.
  67.  
  68.  
  69.  
  70.  
  71.  
  72.  
  73.           2. FM Design Philosophy
  74.  
  75.                Since the FAT is such a crucial data structure, FM takes 
  76.           precautions to ensure the file structure on the target disk is
  77.           not corrupted.  Specifically:
  78.  
  79.                The B, G and R commands to change the status of a cluster
  80.           always give unambiguous feedback showing the results of the
  81.           command.  
  82.  
  83.                FM will not allow you to change the status of a cluster that
  84.           is occupied by file or subdirectory.
  85.  
  86.                The C command shows a history of all changes since running
  87.           FM, so you can't forget what you have done.
  88.  
  89.                FM copies the FAT of the target disk into memory and works
  90.           with the memory copy.  It writes the FAT back to disk only when
  91.           you quit, and only if you give final approval.  You can also
  92.           abort FM with control-c without changing the disk FAT.
  93.  
  94.  
  95.  
  96.  
  97.  
  98.  
  99.           3. One Word Of Caution
  100.  
  101.                FM is not an every day utility - it is more a last resort. 
  102.           FM performs a function normally thought to be left to DOS only. 
  103.           Certainly, DOS assumes no applications program would ever change
  104.           the FAT in any way.  Therefore, FM must be used realizing this,
  105.           and with a certain amount of caution as discussed below.
  106.  
  107.                Do not run FM while on a network or in any situation where a
  108.           new file could be created on disk while FM is running.  Either
  109.           remove or make sure you don't use any memory resident utilities
  110.           which can create a new file on the target disk (eg the Sidekick
  111.           Notepad).
  112.  
  113.                FM reads the FAT only once at startup, and then works with a
  114.           memory copy of it.  Thus, it cannot detect a new file created on
  115.           the target disk while it is running.  So, if you tell FM to write
  116.           a new FAT at the end of a session, any new file will still be in
  117.           its directory, but its allocated clusters will be overwritten. 
  118.           You will then find it difficult or impossible to read or copy
  119.           this file.  This will only affect your new file, however, and
  120.           running CHKDSK/F will make things right again.
  121.  
  122.                FM has one insecurity, because the C, F, and L commands
  123.           allow you to redirect their output to a disk file.  If you
  124.           redirect output to the target disk you be in the situation
  125.           described above.  Again, CHKDSK/F will fix the problem.
  126.  
  127.  
  128.  
  129.  
  130.  
  131.  
  132.                Finally, if you change the FAT and write a new one to a hard
  133.           disk, reboot DOS after exiting FM.  This is because DOS keeps
  134.           part of the FAT in its own memory, and doesn't know the FAT has
  135.           been changed.  Therefore, if you don't reboot DOS may allocate
  136.           disk space based on its outdated information about the FAT.
  137.  
  138.  
  139.  
  140.  
  141.           4. Running FM
  142.  
  143.                FM runs on IBM-PC's AT's and clones using MS-DOS v 2.0 and
  144.           later.  To run, FM requires anywhere from 66K of RAM (for a 360K
  145.           floppy) up to 160K (for a 30MB hard disk).  Up to 2000 files may
  146.           exist on the disk, and as many as 100 subdirectories.  FM may not
  147.           work on some disks formatted by DOS v 1.x.
  148.  
  149.                Run CHKDSK/F on the target disk to remove orphaned clusters. 
  150.           This is recommended but not necessary.
  151.  
  152.                At the DOS prompt, type FM [d].  [d] is an optional drive
  153.           specifier; if you don't specify the drive, FM will type brief
  154.           operating instructions.
  155.  
  156.                Once started, FM will read the boot sector to get basic
  157.           information about the structure of the disk.  Disks formatted by
  158.           DOS v 1 have a different boot sector format from those formatted
  159.           by DOS v 2 and later; FM will not work with v1 disks.
  160.  
  161.                FM then reads all copies of the FAT (typically there are
  162.           two).  FM will compare all copies with each other, checking for
  163.           differences; if the copies are different FM will inform you and
  164.           ask your permission to assume the first FAT copy is the good one. 
  165.           If you have been using the disk with no problems, just say yes,
  166.           and FM will then overwrite the bad copy with the good one at quit
  167.           (see Q command below) time.
  168.  
  169.                Finally, FM reads the entire directory structure on the disk
  170.           and notes the name of the file occupying each cluster of the
  171.           disk.
  172.  
  173.  
  174.  
  175.  
  176.  
  177.  
  178.           5.  FM Commands
  179.  
  180.           Once up and running FM accepts the following commands.
  181.  
  182.  
  183.  
  184.  
  185.           SPECIFYING CLUSTERS AND SECTORS
  186.  
  187.           When you want to examine or change a cluster, FM gives you the
  188.           option of specifying either the cluster, or any of the logical
  189.           sectors that make up the cluster.  To specify a cluster type 'C'
  190.           followed by the cluster number,  no intervening spaces. To
  191.           specify a logical sector type 'S' followed by the sector number;
  192.           FM then operates on the entire cluster of which that sector is a
  193.           part.  You may use the N command, described below, to specify the
  194.           number base of your input.  If you make a mistake FM comes back
  195.           with some help.  If you find you want to abort a B, E, G or R
  196.           command, just hit the return (enter) key.
  197.  
  198.  
  199.  
  200.           CTRL-C
  201.  
  202.           Type ctrl-c at the command prompt to abort FM and return to DOS
  203.           with the FAT unchanged.
  204.  
  205.  
  206.  
  207.  
  208.           THE ? COMMAND
  209.  
  210.           Lists a command summary, the current number base, and shows the
  211.           legal range of values for cluster and sector numbers.
  212.  
  213.  
  214.  
  215.  
  216.           THE B COMMAND 
  217.  
  218.           Marks the specified cluster bad, preventing DOS from writing to
  219.           it.  You enter the cluster or sector number in the current number
  220.           base, controlled b